<%@ page language="java" import="java.util.*,java.net.URLDecoder" pageEncoding="utf-8"%>
<%@taglib uri="http://java.sun.com/jsp/jstl/core" prefix="c" %>
<%
String path = request.getContextPath();
String basePath = request.getScheme()+"://"+request.getServerName()+":"+request.getServerPort()+path+"/";
String loginName="";
String uid="";
Cookie[] cookArr = request.getCookies();
if(cookArr!=null){
	for(Cookie c:cookArr){
		if(c.getName().equals("LOGINNAME")){
			loginName = URLDecoder.decode(c.getValue(),"UTF-8");
		}
		if(c.getName().equals("UID")){
			uid = c.getValue();
		}
		c.getValue();
	}
}
%>


<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
  <head>
    <base href="<%=basePath%>">
    
    <title>修改信息</title>
    
	<meta http-equiv="pragma" content="no-cache">
	<meta http-equiv="cache-control" content="no-cache">
	<meta http-equiv="expires" content="0">    
	<meta http-equiv="keywords" content="keyword1,keyword2,keyword3">
	<meta http-equiv="description" content="This is my page">
	<!--
	<link rel="stylesheet" type="text/css" href="styles.css">
	-->
	<link rel="stylesheet" type="text/css" href="css/my.css"/>
  </head>
    <script type="text/javascript">
		function my(){
			var msg = '${MSG}';
			if(msg!=""){
				alert(msg);
			}
		}
		
	 	
	</script>
  <body >
	<form action="<%=basePath %>buyer/editBuyer.do" enctype="multipart/form-data" method="post">
			<div class="big">
				<div class="head"><h2>修改个人信息</h2></div>
				<input type="hidden" name="uid" value="${buyer.uid}">
				<div class="main">
					<div class="main_left">
						<ul style="list-style: none;">
							<li>用户名：</li>
							<li>原密码：</li>
							<li>新密码：</li>
							<li>头像：</li>
							<li id="left_li">头像审核状态：</li>
						</ul>
					</div>
					<div class="main_right">
						<ul style="list-style: none;">
							<li><input type="text" name="uname" value="${buyer.uname}" readonly="true"></li>
							<li><input type="text" placeholder="请输入原密码" name="upassword" value="${buyer.upassword}" readonly="true"></li>
							<li><input type="text" placeholder="请输入新密码" name="newPassword" value=""></li>
							<li id="pic">
								<c:if test="${buyer.upicture!=null}">
			    					<img src="${buyer.upicture}" width="70px" height="70px"/>
			    				</c:if>
			    				<input type="hidden" name="upicture" value="${buyer.upicture}">
		    					<input type="file" name="pictureFile"/>
							</li>
							<li id="statue">
								<c:if test="${buyer.utype==null}">
			    					未提交审核
			    				</c:if>
			    				<c:if test="${buyer.utype==0}">
			    					提交审核
			    				</c:if>
			    				<c:if test="${buyer.utype==1}">
			    					通过审核
			    				</c:if>
			    				<c:if test="${buyer.utype==4}">
			    					审核未通过
			    				</c:if>
							</li>
						</ul>
						
					</div>
				</div>
				<div class="footer">
					<input class="bt1" type="submit" value="修改">
				</div>
			</div>
		</form>
  </body>
</html>
